<?php
/**
 * Receives a WallSocket id and coordinates
 *  and updates database
 */
require_once('php/MyDB.php');
require_once('php/WallSocket.php');
require_once('php/login.php');


$wallSocket = new WallSocket();
$wallSocket->setId($_GET['id']);
$wallSocket->setCoordX($_GET['coordX']);
$wallSocket->setCoordY($_GET['coordY']);
$wallSocket->setUsed($_GET['used']);
//$wallSocket->setUser($_SESSION['username']);
$wallSocket->setDate($date);

$db = new MyDB();
$db->updateSocket($wallSocket);
$db->disconnect();
